import requests


headers = {
    "host": "match.yuanrenxue.cn",
    "content-length": "0",
    "sec-ch-ua-platform": "\"Windows\"",
    "user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36",
    "sec-ch-ua": "\"Not)A;Brand\";v=\"8\", \"Chromium\";v=\"138\", \"Google Chrome\";v=\"138\"",
    "sec-ch-ua-mobile": "?0",
    "accept": "*/*",
    "origin": "https://match.yuanrenxue.cn",
    "sec-fetch-site": "same-origin",
    "sec-fetch-mode": "cors",
    "sec-fetch-dest": "empty",
    "referer": "https://match.yuanrenxue.cn/match/3",
    "accept-encoding": "gzip, br",
    "accept-language": "zh-CN,zh;q=0.9",
    "cookie": "sessionid=tnzxznc379a077uh3wbfltrhdm87i3sc",
    "priority": "u=0, i"
}
cookies = {
    "sessionid": "tnzxznc379a077uh3wbfltrhdm87i3sc"
}
url = "https://match.yuanrenxue.cn/api/match/3"



list_a = []
for i in range(5):
    params = {
        "page": i + 1
    }
    session = requests.session()
    session.headers = headers
    session.post('https://match.yuanrenxue.cn/jssm')
    response = session.get(url, params=params, proxies={"http": None, "https": None})
    json_data = response.json()
    list_a += json_data['data']
# 找出出现次数最多的元素（如果有多个，只返回第一个）
most_common = max(list_a, key=list_a.count)
print(most_common['value'])
